-- GENERATED SPELL FOR [Bladespire Enforcer] --


function spell0_19997(pUnit, Event) --@Enrage,Self--
pUnit:FullCastSpellOnTarget(8599,pUnit)
pUnit:RegisterEvent('Sorts_19997', 520, 1)
end

function spell1_19997(pUnit, Event) --@Thunderclap,Self--
pUnit:FullCastSpellOnTarget(15588,pUnit)
pUnit:RegisterEvent('Sorts_19997', 10320, 1)
end

function Sorts_19997(pUnit, Event)
local choix_sorts_19997 = math.random(0, 1)
if choix_sorts_19997 == 0 then
pUnit:RegisterEvent('spell0_19997', 1, 1)
end
if choix_sorts_19997 == 1 then
pUnit:RegisterEvent('spell1_19997', 1, 1)
end
end

function mob19997_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_19997', math.random(1500, 3000), 1)
end

function mob19997_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob19997_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob19997_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(19997, 1, 'mob19997_Action')
RegisterUnitEvent(19997, 2, 'mob19997_Leave')
RegisterUnitEvent(19997, 3, 'mob19997_Kill')
RegisterUnitEvent(19997, 4, 'mob19997_Die')
